package com.ruiyian.system.service.impl;

import com.ruiyian.system.domain.ServerEq;
import com.ruiyian.system.domain.vo.ServerEqFormal;
import com.ruiyian.system.mapper.ServerMapper;
import com.ruiyian.system.service.ServerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author chong
 * @email 673426164@qq.com
 * @create 2021/8/24
 * Desc: 服务实现
 */
@Service
public class ServerServiceImpl implements ServerService {
    @Autowired
    private ServerMapper serverMapper;
    @Override
    public void save(ServerEq server) {
        serverMapper.save(server);
    }

    @Override
    public List<ServerEq> selectList(ServerEq server) {
        return serverMapper.selectList(server);
    }

    @Override
    public void update(ServerEq server) {
        serverMapper.update(server);
    }

    @Override
    public void delete(Long id) {
        serverMapper.delete(id);
    }

    @Override
    public ServerEq findOne(Long id) {
        return serverMapper.findOne(id);
    }

    @Override
    public List<ServerEq> selectTaskServer() {
        return serverMapper.selectTaskServer();
    }

    @Override
    public List<ServerEq> selectServerByTunnelId(Long tunnelId, long moduleId) {
        return serverMapper.selectServerByTunnelId(tunnelId, moduleId);
    }

    @Override
    public List<ServerEqFormal> selectServerformalByInfo(int tunnelId, int moduleId, String server_name_en) {
        return serverMapper.selectServerformalByInfo(tunnelId, moduleId, server_name_en);
    }
}
